Bounded Polymorphism for Extensible Objects
نویسنده
چکیده
In the ECOOP’97 conference, the author of the present paper investigated a conservative extension, called Ob+1<:, of the first-order Object Calculus Ob1<: of Abadi and Cardelli, supporting method extension in presence of object subsumption. In this paper, we extend that work with explicit variance annotations and selftypes. The resulting calculus, called Ob+s<:, is a proper extension of Ob+1<:. Moreover it is proved to be type sound. Categories. Type systems, design and semantics of object-oriented languages.
منابع مشابه
History of Object Calculi
Records are used to model objects. A record is a function from labels to values. With record calculi, the set of messages that can be sent to objects is bounded by the set of its labels. Furthermore, records do not faithfully model objects. Two milestones in this phase are [3] and [8]. In [3], objects are modelled as read-only, recursive, fixed size records. Types are syntactic objects. A synta...
متن کاملA Subtyping for Extensible, Incomplete Objects
We extend the type system for the Lambda Calculus of Objects 16] with a mechanism of width subtyping and a treatment of incomplete objects. The main novelties over previous work are the use of subtype-bounded quantiication to capture a new and more direct rendering of MyType polymorphism, and a uniform treatment for other features that were accounted for via diierent systems in subsequent exten...
متن کاملObject-Oriented Verification Based on Record Subtyping in Higher-Order Logic
We show how extensible records with structural subtyping can be represented directly in Higher-Order Logic (HOL). Exploiting some speci c properties of HOL, this encoding turns out to be extremely simple. In particular, structural subtyping is subsumed by naive parametric polymorphism, while overridable generic functions may be based on overloading. Taking HOL plus extensible records as a start...
متن کاملGame Semantics for Bounded Polymorphism
We describe a denotational, intensional semantics for programs with polymorphic types with bounded quantification, in which phenomena such as inheritance between stateful objects may be represented and studied. Our model is developed from a game semantics for unbounded polymorphism, by establishing dinaturality properties of generic strategies, and using them to give a new construction for inte...
متن کاملAn Interpretation of Extensible Objects
We provide a translation of Fisher-Honsell-Mitchell's delegation-based object calculus with sub-typing into a-calculus with extensible records. The target type system is an extension of the system F ! of dependent types with recursion, extensible records and a form of bounded universal quantiication. We show that our translation is computationally adequate, that the typing rules of Fisher-Honse...
متن کامل